using MediatR;
using RBAC.ErrorCode;
using RBAC.Read.Api.Application.Dto.ERP.SalesManagement.H;
using System;
using System.Collections.Generic;

namespace RBAC.Read.Api.Application.Command.ERP.SalesManagement.H
{
    /// <summary>
    /// 获取发货通知单列表命令
    /// </summary>
    public class GetDeliveryNoticeListCommand : IRequest<APIResult<GetDeliveryNoticeListDto>>
    {
        /// <summary>
        /// 销售订单号
        /// </summary>
        public string? SalesOrderCode { get; set; }

        /// <summary>
        /// 单据编码
        /// </summary>
        public string? BillCode { get; set; }

        /// <summary>
        /// 客户名称
        /// </summary>
        public string? CustomerName { get; set; }

        /// <summary>
        /// 销售员
        /// </summary>
        public string? SalesmanName { get; set; }

        /// <summary>
        /// 单据状态（0=开立，1=审核，2=退回），可选
        /// </summary>
        public int? Status { get; set; }

        /// <summary>
        /// 业务类型（如 普通发货、直运发货），可选
        /// </summary>
        public string? BizType { get; set; }

        /// <summary>
        /// 物料名称
        /// </summary>
        public string? MaterialName { get; set; }

        /// <summary>
        /// 开始日期
        /// </summary>
        public DateTime? StartDate { get; set; }

        /// <summary>
        /// 结束日期
        /// </summary>
        public DateTime? EndDate { get; set; }

        /// <summary>
        /// 页码
        /// </summary>
        public int PageIndex { get; set; } = 1;

        /// <summary>
        /// 每页大小
        /// </summary>
        public int PageSize { get; set; } = 10;
    }

    /// <summary>
    /// 发货通知单列表查询结果DTO
    /// </summary>
    public class GetDeliveryNoticeListDto
    {
        /// <summary>
        /// 总记录数
        /// </summary>
        public int TotalCount { get; set; }

        /// <summary>
        /// 发货通知单列表
        /// </summary>
        public List<DeliveryNoticeListDto> Items { get; set; } = new List<DeliveryNoticeListDto>();
    }
} 